package DesignPatern.A14_迭代器模式.QSB.A03_抽象模式;

/**
 * @Author: Du
 * @Date: 2021/8/2 8:52
 */
public class A01_Main
{
    public static void main(String[] args)
    {
        Aggregate agg = new ConcreteAggregate();
        
        agg.add("abc");
        agg.add("aaa");
        agg.add("111");
        
        Iterator it = agg.iterator();
        
        while (it.hasNext())
        {
            System.out.println(it.next());
        }
    }
}
